From: Anthony PERARD Date: Mon, 8 Oct 2012 10:45:29 +0000 (+0100) Subject: libxl: Add a comment about NOGC usage with flexarray X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~7810 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/%22bookmarks://%22Dat/%22http:/www.example.com/cgi/%22https:/%22bookmarks:/%22Dat?a=commitdiff_plain;h=4457702a84713bf06dc861bc2873b964dd6fa949;p=xen.git libxl: Add a comment about NOGC usage with flexarray Signed-off-by: Anthony PERARD Acked-by: Ian Jackson Committed-by: Ian Campbell --- diff --git a/tools/libxl/flexarray.h b/tools/libxl/flexarray.h index aade417906..a1e86475c4 100644 --- a/tools/libxl/flexarray.h +++ b/tools/libxl/flexarray.h @@ -26,7 +26,13 @@ typedef struct flexarray { struct libxl__gc *gc; } flexarray_t; -_hidden flexarray_t *flexarray_make(struct libxl__gc *gc, int size, int autogrow); +/* + * NOGC can be used with flexarrays, but flexarray_free will need to be called + * to free the struct. The content of the flexarray will not be freed through + * flexarray_free. + */ +_hidden flexarray_t *flexarray_make(struct libxl__gc *gc_opt, + int size, int autogrow); _hidden void flexarray_free(flexarray_t *array); _hidden void flexarray_grow(flexarray_t *array, int extents); _hidden int flexarray_set(flexarray_t *array, unsigned int index, void *ptr);